<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        div {
            width: 30px;
            height: 30px;
            margin: 30px auto;
        }
        
        @keyframes zhuan1 {
            0% {
                transform: rotate(0deg);
            }
            100% {
                transform: rotate(360deg);
            }
        }
        
        .d1 {
            /*动画名称*/
            animation-name: zhuan1;
            /* 动画执行时间 */
            animation-duration: 2s;
            /* 动画执行方式 */
            animation-timing-function: linear;
            /* 延迟执行动画执行的时间 */
            animation-delay: 1s;
            /* 动画执行次数  (infinite 无线循环)  单独写数字，表示执行次数，不能为负值*/
            animation-iteration-count: infinite;
        }
        
        .d2 {
            animation-name: zhuan1;
            animation-duration: 2s;
            animation-timing-function: steps(8)
        }
    </style>
</head>

<body>
    <div class="d1"><img src="./img/loading-a.png" alt=""></div>
    <div class="d2"><img src="./img/loading-b.png" alt=""></div>
</body>

</html>